//接口日志
"use strict"
const mvc = require("cosjs.mvc")
const dbase = mvc.model.require("dbase");

class apiLog extends dbase.gzone.mongodb {
    constructor(sid) {
        super(sid, 'apiLog', true);
    }

    push(data) {
        data['_id'] = this.ObjectID();
        return this.insert(data);
    }
}


module.exports = function (sid) {
    return new apiLog(sid);
};



//索引
module.exports.indexes = [
    [{ "uid": 1, "time": 1 }, {}]
]